<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib prefix="s" uri="/struts-tags"%>
<%@ taglib prefix="e" uri="/easytogo-tags"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title>登录</title>
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0"> 
	<e:base/>   
	<script type="text/javascript">
		function to_login(){
			var admin="0";
			var remember="0";
			if($("#admin").attr("checked")){
				admin="1";
			}
			if($("#remember").attr("checked")){
				remember="1";
			}
			parent.location="${pageContext.request.contextPath}/appuser/appuser_login.action?username="+$("#username").val()+"&password="+$("#password").val()+"&admin="+admin+"&remember="+remember;
		}
    </script>
  </head>
  
  <body>
  	<form action="${pageContext.request.contextPath }/appuser/appuser_login.action" method="post">
	   <table border="1">
	    	<tr>
	    		<td colspan="3"><font color="red">${msg1 }</font></td>
	    	</tr>
	    	<tr>
	    		<td>用户名</td><td><input id="username" name="username" type="text" value="${username }"/></td><td></td>
	    	</tr>
	    	<tr>
	    		<td>密码</td><td><input id="password" name="password" type="password" value="${password }"/></td><td></td>
	    	</tr>
	    	<tr>
	    		<td colspan="3">
	    			<input id="admin" type="checkbox" name="admin" value="1" <s:if test="admin==1">checked</s:if>/>管理员
	    		</td>
	    	</tr>
	    	<tr>
	    		<td colspan="3">
	    		<input id="remember" type="checkbox" name="remember" value="1" <s:if test="remember==1">checked</s:if>/>记住配置
	    		<input type="submit" value="登录"/>&nbsp;&nbsp;&nbsp;&nbsp;<a href="appuser/regist.jsp">注册</a></td>
	    	</tr>
	    </table>
	  </form>
  </body>
</html>
